<template>
  <section :class="struc_class">
    <div class="header" v-if="header" @touchmove.prevent.stop>
      <slot name="header"></slot>
    </div>
    <div class="main" v-scroll>
      <div class="main-scroll">
        <slot name="main"></slot>
      </div>
    </div>
    <div class="footer" v-if="footer" @touchmove.prevent.stop>
      <slot name="footer"></slot>
    </div>
  </section>
</template>

<script>
  export default {
    name: "struc",
    props: {
      header: {
        type: Boolean,
        default: false
      },
      footer: {
        type: Boolean,
        default: false
      }
    },
    data() {
      return {
        struc_class: {
          struc: true,
          noHeader: !this.header,
          noFooter: !this.footer
        },
        timer: null
      }
    }
  }
</script>

<style lang="scss" scoped>

</style>
